package ast;

import org.eclipse.jdt.core.dom.CompilationUnit;

import fuck.bean.Field;

public class Test {

	public static void main(String[] args) {
		
		CompilationUnit comp = JdtAstUtil.getCompilationUnit("E:/sourcetreerepo/fuck/src/ast/ASTBean.java");  
		
		DemoVisitor visitor = new DemoVisitor();  
		comp.accept(visitor);  
		
		FieldsVisitor fv = new FieldsVisitor();
		comp.accept(fv);
		
		for(Field f : fv.getFieldList()){
			System.out.println(f);
		}
	}
	
	//AST创建代码与ASM创建class
	
	//AST可以分析源代码,然后根据源代码生成需要的代码,这里只需要分析的结果就可以了
}
